package com.itfreer.gis.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import org.springframework.beans.BeanUtils;

import com.itfreer.form.api.JdbcBaseEntity;
/**
 * 统计类型详细
 * @author gj
 *
 */
@Entity(name = "gis_analysis_c_view")
@Table(indexes = { 
        })
public class JdbcGisStatisticsCategoryDetailsViewEntity 
implements JdbcBaseEntity<GisStatisticsCategoryDetailsViewEntity>, Serializable {

	private static final long serialVersionUID = 8956058710867750399L;

	/**
	 * 数据库主键
	 */
	@Id
	@Column(name="s_id")
	private String id;
	/**
	 * 关联的分析图层配置的id
	 */
	@Column(name="p_id")
	private String pid;
	
	/**
	 * 统计字典关联的id
	 */
	@Column(name="field_id")
	private String fieldid;
	
	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}
	public String getPid() {
		return pid;
	}
	public void setPid(String pid) {
		this.pid = pid;
	}
	public String getFieldid() {
		return fieldid;
	}
	public void setFieldid(String fieldid) {
		this.fieldid = fieldid;
	}
	
	/**
	 * 字段名称
	 */
	@Column(name="s_name")
	private String name;

	/**
	 * 字段别名
	 */
	@Column(name="s_aliasname")
	private String aliasName;
	
	/**
	 * 排序值
	 */
	@Column(name="i_order")
	private Integer order;

	public Integer getOrder() {
		return order;
	}

	public void setOrder(Integer order) {
		this.order = order;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getAliasName() {
		return aliasName;
	}

	public void setAliasName(String aliasName) {
		this.aliasName = aliasName;
	}
	@Override
	public void from(GisStatisticsCategoryDetailsViewEntity t) {
		BeanUtils.copyProperties(t, this);
	}
	@Override
	public GisStatisticsCategoryDetailsViewEntity toEntity() {
		GisStatisticsCategoryDetailsViewEntity toEntity = new GisStatisticsCategoryDetailsViewEntity();
		BeanUtils.copyProperties(this, toEntity);
		return toEntity;
	}
}
